put element into ascending order